//(3).处理异步数据
import axios from "axios"
export default  {
    waitadd({commit}){
        setTimeout(() => {
            commit("add")
        }, 1500);
    },

    waitaddN({commit} , payload){
        setTimeout(() => {
            commit("addN" , payload)
        }, 1500);
    },

    async getmovieList({commit}){
        const result = await axios.get(
            "https://pcw-api.iqiyi.com/search/recommend/list?channel_id=1&data_type=1&mode=11&page_id=2&ret_num=48&session=b9fd987164f6aa47fad266f57dffaa6a"
        );
        commit("getMovieList" , result.data.data.list)
    }
}